﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace WodLib.Tools
{
    public static class WodObjectClipboard
    {
        private static WodObject temmporary = null;

        /// <summary>
        /// Creates new instance of object.
        /// </summary>
        static WodObjectClipboard()
        {

        }

        public static void Copy(WodObject objToCopy)
        {
            if(objToCopy is ICloneable)
                temmporary = objToCopy;
        }

        public static WodObject Paste()
        {
            if (temmporary == null)
                return null;

            return (WodObject)(temmporary as ICloneable).Clone();
        }
    }
}
